<?php


class Address extends Eloquent{


	/**
	 * The database table used by the model.
	 *
	 * @var string
	 */

public function street(){
		$street = $this->belongsTo('Street', 'street_id');
		return $street != null ? $street : null;
	}

public function coordinateOfAddress(){
		$coordinateOfAddress = $this->belongsTo('Coordinate', 'coordinate_id');
		return $coordinateOfAddress != null ? $coordinateOfAddress : null;
	}

public function placeInfomation(){
		$placeInfomation = $this->hasMany('PlaceInfomation','address_id');
		return $placeInfomation !=null ? $placeInfomation:null;
}